{extend name="../../admin/view/main"}

{block name="content"}

<div class="layui-tab layui-tab-card think-bg-white">

    <div class="layui-tab-content">

        {include file='plan/index_search'}

        <table class="layui-table margin-top-10" lay-skin="line">
            {notempty name='list'}
            <thead>
            <tr>
                <th class='list-table-check-td think-checkbox'>
                    <label><input data-auto-none data-check-target='.list-check-box' type='checkbox'></label>
                </th>
                <!-- <th class='list-table-sort-td'>
                    <button class="layui-btn layui-btn-xs" data-reload type="button">刷 新</button>
                </th> -->
                <th class='text-left nowrap'>还款计划ID</th>
                <th class='text-left nowrap'>订单ID</th>
                <th class='text-left nowrap'>店铺名称</th>
                <th class='text-left nowrap'>用户信息</th>
                <th class='text-left nowrap'>期数</th>
                <th class='text-left nowrap'>违约金</th>
                <th class='text-left nowrap'>费用明细</th>
                <th class='text-left nowrap'>减免金额</th>
                <th class='text-left nowrap'>应收</th>
                <th class='text-left nowrap'>逾期天数</th>
                <th class='text-left nowrap'>应还款日期</th>
                <th class='text-left nowrap'>支付时间</th>
                <th class='text-left nowrap'>还款状态</th>
                <th class='text-left nowrap'>是否退款</th>
                <th></th>
            </tr>
            </thead>
            {/notempty}
            <tbody>
            {foreach $list as $key=>$vo}
            <tr>
                <td class='list-table-check-td think-checkbox'>
                    <label><input class="list-check-box" type='checkbox' value='{$vo.order_id}'></label>
                </td>

                <td class='nowrap'><span>{$vo.plan_id|default='--'}</span></td>
                <td class='nowrap'><span><a data-open="{:url('admin/order/index')}?order_id={$vo.order_id}">{$vo.order_id|default='--'}</a></span></td>
                <td class='nowrap'><span>{$vo.shop_name|default='--'}</span></td>
                <td class='nowrap'>
                    <div class="inline-block text-top ">
                        <div><span>{$vo.name|default='--'}</span></div>
                        <div><span>{$vo.mobile|default='--'}</span></div>
                    </div>
                </td>
                <td class='nowrap'><span>{$vo.plan_index|default='--'}/12</span></td>
                <td class='nowrap'><span>{$vo.overdue_fine|default='0.00'}</span></td>
                <td class='nowrap'>
                    租金：{$vo.plan_amount}<br>
                    {if $vo.plan_index == 12 }买断尾款：{$vo.buy_amount}{/if}
                </td>
                <td class='nowrap'>
                    --
                </td>
                <td class='nowrap'>{$vo.plan_total_amount|default='--'}</td>
                <td class='nowrap'>{$vo.overdue_day|default='--'}</td>
                <td class='nowrap'>{$vo.plan_date|default='--'}</td>
                <td class='nowrap'>--</td>
                <td class='nowrap'>{$vo.status_str|default='--'}</td>
                <td class='nowrap'>
                    <span class="layui-badge layui-bg-gray layui-border-red">{$vo.refund_sts == 1 ? '是' : '否'}</span>
                </td>
            </tr>
            {/foreach}
            </tbody>
        </table>
        {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
    </div>
    <script>form.render()</script>
</div>
{/block}
